#!/usr/bin/env python3
# -*- coding: utf-8 -*-

__author__ = 'teffy'

'''
@created on 17-11-8
@poject:python-shoot-game
@author:teffy
'''

class Settings(object):
    def __init__(self):
        self.screen_width = 1200
        self.screen_height = 700
        self.bg_color = (230,230,230)
        self.ship_limit = 3
        self.bullet_width = 3
        self.bullet_height = 15
        self.bullet_color = (160,160,60)
        self.bullet_max_count = 5
        self.enemy_drop_speed = 10
        self.speedup_scale = 1.1
        self.score_scale = 1.5
        self.config_file = './.config'
        self.config_high_score_key = 'high_score'
        self.initialize_dynamic_settings()

    def initialize_dynamic_settings(self):
        self.ship_speed_factor = 1.5
        self.bullet_speed_factor = 3
        self.enemy_speed_factor = 1
        self.enemy_move_direction = 1

        self.enemy_point = 50


    def increase_speed(self):
        '''提高速度'''
        self.ship_speed_factor *= self.speedup_scale
        self.bullet_speed_factor *= self.speedup_scale
        self.enemy_speed_factor *= self.speedup_scale
        self.enemy_point = int(self.enemy_point * self.score_scale)
